home *** CD-ROM | disk | FTP | other *** search
- ############################################################# -*- c -*-
- ## generic include for XXX. Do not use directly.
- ##
- ## $Id: generic-value-map-reverse.m2i,v 1.6.2.1 2005/05/21 15:09:24 rstory Exp $
- ########################################################################
- @if $m2c_mark_boundary == 1@
- /** START code generated by $RCSfile: generic-value-map-reverse.m2i,v $ $Revision: 1.6.2.1 $ */
- @end@
- ########################################################################
- ##
- /*
- * TODO:245:o: |-> Implement $node reverse mapping.
- * If the values for your data type don't exactly match the
- * possible values defined by the mib, you should map them here.
- */
- ##&& ($node.syntax ne $node.perltype)
- @ if ("$node.perltype" eq "INTEGER") && ($node.enums == 1)@
- $example_start
- switch($m2c_node_srh) {
- @ foreach $e $v enum@
- @ include m2c_setup_enum.m2i@
- case $m2c_ename:
- $m2c_node_srh = INTERNAL_$m2c_iname;
- break;
-
- @ end@ # foreach
- default:
- snmp_log(LOG_ERR, "couldn't reverse map value %ld for $node\n", $m2c_node_srh );
- return SNMP_ERR_GENERR;
- }
- $example_end
-
- @end@
- ##
- ########################################################################
- @if $m2c_mark_boundary == 1@
- /** END code generated by $RCSfile: generic-value-map-reverse.m2i,v $ $Revision: 1.6.2.1 $ */
- @end@
-